package com.gjy.cloud.service.impl;

import com.gjy.cloud.entities.Payment;
import com.gjy.cloud.mapper.PaymentMapper;
import com.gjy.cloud.service.PaymentService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

/**
 * @author 宫静雨
 * @version 1.0
 */
@Service
@Transactional
public class PaymentServiceImpl implements PaymentService {

    @Resource
    private PaymentMapper paymentMapper;

    @Override
    public int create(Payment payment) {
        return paymentMapper.create(payment);
    }

    @Override
    public Payment getPaymentById(Long id) {
        return paymentMapper.getPaymentById(id);
    }
}